<?php

/**
 * cms actions.
 *
 * @package    beamr
 * @subpackage cms
 * @author     Your name here
 * @version    SVN: $Id: actions.class.php 12479 2008-10-31 10:54:40Z fabien $
 */
class cmsActions extends sfActions
{
 /**
  * Executes index action
  *
  * @param sfRequest $request A request object
  */
  public function executeIndex(sfWebRequest $request)
  {
    $url = $request->getParameter('url');
    if (is_null($url)) {
      $url = 'homepage';
    }
    $this->page = Doctrine::getTable('Page')->getPage($url);
    $this->forward404Unless($this->page, 'This page does not exist.');
  }
}
